<?php
    //$filename = "FileToBeRead.txt";
    $filename = "myCVSFile.csv";
    $fd = fopen ($filename, "r");
    $contents = fread ($fd,filesize ($filename));

    fclose ($fd); 
    $delimiter = ";";
    $splitcontents = explode($delimiter, $contents);
    $counter = "";
?>
<font color="blue" face="arial" size="4">Complete File Contents</font>
<hr>
<?php 
    echo $contents;
?>

<br><br>
<font color="blue" face="arial" size="4">Split File Contents</font>
<hr>
<?php 
foreach ( $splitcontents as $color ) {
    $counter = $counter+1;
    echo "<b>Split ".$counter.": </b>".$color."<br>";
}
?>